/**
 * 文件url
 */
import request from '/@/utils/request';

export function preview(name: string) {
  return request({
    url: 'file/preview',
    method: 'get',
    params: {
      name,
    },
  });
}

export function download(filename: string) {
  return request({
    url: `file/download?filename=${filename}`,
    method: 'get',
    responseType: 'blob',
  });
}
